﻿using System;
using Newtonsoft.Json.Linq;
using JsonCSharpClassGenerator;

namespace MyVideoTek
{

    internal class CreateMovie
    {

        public CreateMovie(string json)
         : this(JObject.Parse(json))
        {
        }

        private JObject __jobject;
        public CreateMovie(JObject obj)
        {
            this.__jobject = obj;
        }

        [System.Diagnostics.DebuggerBrowsable(System.Diagnostics.DebuggerBrowsableState.Never)]
        private Movie _movie;
        public Movie Movie
        {
            get
            {
                if(_movie == null)
                    _movie = JsonClassHelper.ReadStronglyTypedObject<Movie>(JsonClassHelper.GetJToken<JObject>(__jobject, "movie"));
                return _movie;
            }
        }

    }
}
